from pydantic import BaseModel
from typing import Optional
from datetime import datetime

class PptCallbackData(BaseModel):
    uid: str
    pptId: str
    name: str
    subject: str
    coverUrl: str
    fileUrl: str
    createTime: datetime

class TemplateCallbackData(BaseModel):
    uid: str
    templateId: str
    coverUrl: str
    fileUrl: str
    createTime: datetime

class CallbackRequest(BaseModel):
    event: str
    data: PptCallbackData | TemplateCallbackData

class CallbackResponse(BaseModel):
    ok: bool
    msg: str 